﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Messhall.Framework.Domain.DomainObject;

namespace Messhall.Domain.System.BusinessObjects
{
    public class UserBalanceBill : EntityBoBase
    {
        #region 成员变量

        public Guid UserKeyId { get; private set; }

        /// <summary>
        /// 出入-类型 1进账 2出账
        /// </summary>
        public short Type { get; private set; }

        /// <summary>
        /// 消费类型
        /// </summary>
        public short ConsumptionType { get; private set; }

        /// <summary>
        /// 变更前
        /// </summary>
        public decimal BeforeMoney { get; private set; }

        /// <summary>
        /// 变更后
        /// </summary>
        public decimal AfterMoney { get; private set; }

        /// <summary>
        /// 变更金额
        /// </summary>
        public decimal Money { get; private set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remark { get; private set; }

        #endregion

        public UserBalanceBill(Guid userKeyId, short type, short consumptionType, decimal beforeMoney, decimal afterMoney, decimal money, string remark)
        {
            Type = type;
            ConsumptionType = consumptionType;
            BeforeMoney = beforeMoney;
            AfterMoney = afterMoney;
            Money = money;
            Remark = remark;
            UserKeyId = userKeyId;
        }

        public void SetUserKeyId(Guid userKeyId)
        {
            this.UserKeyId = userKeyId;
        }

        public void SetType(short type)
        {
            this.Type = type;
        }

        public void SetConsumptionType(short consumptionType)
        {
            this.ConsumptionType = consumptionType;
        }

        public void SetBeforeMoney(decimal beforeMoney)
        {
            this.BeforeMoney = beforeMoney;
        }

        public void SetAfterMoney(decimal afterMoney)
        {
            this.AfterMoney = afterMoney;
        }

        public void SetMoney(decimal money)
        {
            this.Money = money;
        }

        public void SetRemark(string remark)
        {
            this.Remark = remark;
        }
    }
}
